<template>
    <div id="OrdersTitle">
        <v-details :inputConfig="inputConfig" :detailData="inputData" :rules="rules"></v-details>
    </div>
</template>

<script>
    import details from 'commons/Detail'
    import baseMixin from "@/mixins/BaseMixin";

    export default {
        props: {
            inputData: {
                type: Object,
            }
        },
        mixins: [baseMixin],
        name: "OrdersTitle",
        data() {
            return {
                rules: {
                    type: [
                        {required: true, trigger: 'blur'},
                    ],
                    storerkey: [
                        {required: true, trigger: 'blur'},
                    ],
                    wavekey: [
                        {required: true, trigger: 'blur'},
                    ],
                    status: [
                        {required: true, trigger: 'blur'},
                    ]
                },
            }
        },
        computed: {
            inputConfig() {
                return [
                    [
                        {
                            type: "input",
                            label: this.$t('out.orderkey'),
                            props: "orderkey",
                            disabled: true
                        },
                        {
                            type: "input",
                            label: this.$t('ex.taskgroup'),
                            props: "taskgroup",
                            disabled: true
                        }
                    ],
                    [
                        {
                            type: "select",
                            label: this.$t('common.type'),
                            props: "type",
                            options: [
                                {code: '10', description: this.$t('code.checktype1')},
                                {code: '20', description: this.$t('code.checktype2')},
                                {code: '30', description: this.$t('code.checktype3')},
                                {code: '50', description: this.$t('code.checktype4')}
                            ],
                            disabled: true
                        },
                        {
                            type: "input",
                            label: this.$t('config.shipper'),
                            props: "storerkey",
                            disabled: true
                        }
                    ],
                    [
                        {
                            type: "input",
                            label: this.$t('out.wavekey'),
                            props: "wavekey",
                            disabled: true
                        },
                        {
                            type: "select",
                            label: this.$t('common.status'),
                            props: "status",
                            options: [
                                {code: '0', description: this.$t('code.checkstatus1')},
                                {code: '3', description: this.$t('code.checkstatus2')},
                                {code: '9', description: this.$t('code.checkstatus3')}
                            ],
                            disabled: true
                        }
                    ]
                ]

            }
        },
        methods: {},
        mounted() {

        },
        watch: {},
        components: {
            'v-details': details
        }
    }
</script>

<style scoped>

</style>
